package tw.com.softleader.json.jackson.app;

import java.io.InputStream;

import tw.com.softleader.json.jackson.entity.Question01Entity;

import com.fasterxml.jackson.databind.ObjectMapper;

public class Question01App {

	public static void main(String[] args) {
		
		// Read file as InputStream..
		InputStream in = Question01App.class.getResourceAsStream("/question01.json");
		
		Question01Entity q01Entity = null;
		try {
			// TODO 請將 q01Entity 載入 question01.json 的資料
			ObjectMapper objectMapper = new ObjectMapper();		
			
			q01Entity = objectMapper.readValue(in, Question01Entity.class) ;
			
		} catch (Exception e) {
			e.printStackTrace();
		} 
		
		System.out.println(q01Entity);
		
	}
	
}
